Add HTTP method shortcuts and output expression support in DSL#1458
Conversation
There was a problem hiding this comment.
Pull request overview
Note
Copilot was unable to run its full agentic suite in this review.
Adds fluent DSL extensions for HTTP call tasks (HTTP verb shortcuts, headers/content-type helpers, redirect flag, post-configuration via andThen, and outputAs) and introduces tests to validate the new behavior.
Changes:
- Added HTTP verb shortcut methods and convenience helpers (redirect, accept/content-type shortcuts) to the HTTP DSL.
- Added
andThen(...)support onCallHttpSpecto apply additional builder modifications. - Added
outputAs(String)convenience method onCallHttpTaskBuilderand comprehensive JUnit tests for the new DSL features.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| fluent/spec/src/test/java/io/serverlessworkflow/fluent/spec/dsl/CallHttpDslExtensionsTest.java | Adds unit tests covering new HTTP DSL shortcuts, chaining with andThen, and outputAs. |
| fluent/spec/src/main/java/io/serverlessworkflow/fluent/spec/dsl/CallHttpSpec.java | Implements andThen(...) by storing additional steps to apply to the builder. |
| fluent/spec/src/main/java/io/serverlessworkflow/fluent/spec/dsl/BaseCallHttpSpec.java | Adds HTTP verb shortcuts and convenience methods for redirect and common headers. |
| fluent/spec/src/main/java/io/serverlessworkflow/fluent/spec/CallHttpTaskBuilder.java | Adds a convenience outputAs(String) method with Javadoc. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
be067c4 to
4403100
Compare
|
@matheusandre1 Good work, take a look to AI comments |
|
@fjtirado I’d like your opinion on the new |
fjtirado
left a comment
There was a problem hiding this comment.
@matheusandre1 just remove the new deprecated methods and we are ready to go
Signed-off-by: Matheus André <matheusandr2@gmail.com>
Many thanks for submitting your Pull Request ❤️!
What this PR does / why we need it:
Closes: #1435
Special notes for reviewers:
Additional information (if needed):